home *** CD-ROM | disk | FTP | other *** search
/ Nejlepší České Hry / Nej české hry.iso / hry / vesmirna becherovka / 2004 Vesmírná Becherovka / Becherovka.exe / scripts / DefineButton2_1137 / BUTTONCONDACTION on(release).as next >
Encoding:
Text File  |  2004-09-30  |  880 b   |  31 lines

  1. on(release){
  2.    if(_root.s.Control and !copy)
  3.    {
  4.       _root.s.HideSipka();
  5.       this._visible = false;
  6.       this.duplicateMovieClip("DObject",13300);
  7.       _root.s.DObject.swapDepths(0);
  8.       _root.s.DObject.gotoAndStop("pick");
  9.       _root.s.DObject.copy = true;
  10.       _root.s.DObject.origin = this;
  11.       startDrag(_root.s.DObject,0);
  12.    }
  13.    if(copy)
  14.    {
  15.       stopDrag();
  16.       if(eval(this._droptarget) != undefined and eval(this._droptarget) == _root.s.back2.brana)
  17.       {
  18.          _root.s.what = _root.s.hero.name;
  19.          _root.s.cil = "s9_brana";
  20.          _root.s.uses = "eklic";
  21.          _root.s.HideObj();
  22.          _root.s.hero.gotoAndPlay("navrat");
  23.       }
  24.       trace(eval(this._droptarget));
  25.       this._visible = false;
  26.       origin._visible = true;
  27.       _root.s.ShowSipka();
  28.       _root.s.DObject.removeMovieClip();
  29.    }
  30. }
  31.